package com.xliang.spider.version03.pojo;

/**
 *
 * @author xiongl
 * @create 2016-05-19 11:42
 */
public class CourseEntity
{
    private int id;
    
    private int courseId;
    
    private String courseName;
    
    private String chapterName;
    
    private String partName;
    
    private String url;
    
    private int status;
    
    public CourseEntity()
    {
    }
    
    public CourseEntity(int courseId, String courseName, String chapterName, String partName, String url)
    {
        this.courseId = courseId;
        this.courseName = courseName;
        this.chapterName = chapterName;
        this.partName = partName;
        this.url = url;
    }
    
    public int getId()
    {
        return id;
    }
    
    public void setId(int id)
    {
        this.id = id;
    }
    
    public int getCourseId()
    {
        return courseId;
    }
    
    public void setCourseId(int courseId)
    {
        this.courseId = courseId;
    }
    
    public String getCourseName()
    {
        return courseName;
    }
    
    public void setCourseName(String courseName)
    {
        this.courseName = courseName;
    }
    
    public String getChapterName()
    {
        return chapterName;
    }
    
    public void setChapterName(String chapterName)
    {
        this.chapterName = chapterName;
    }
    
    public String getPartName()
    {
        return partName;
    }
    
    public void setPartName(String partName)
    {
        this.partName = partName;
    }
    
    public String getUrl()
    {
        return url;
    }
    
    public void setUrl(String url)
    {
        this.url = url;
    }
    
    public int getStatus()
    {
        return status;
    }
    
    public void setStatus(int status)
    {
        this.status = status;
    }
    
    @Override
    public boolean equals(Object o)
    {
        if (this == o)
            return true;
        if (o == null || getClass() != o.getClass())
            return false;
        
        CourseEntity that = (CourseEntity)o;
        
        if (id != that.id)
            return false;
        if (courseId != that.courseId)
            return false;
        if (status != that.status)
            return false;
        if (!courseName.equals(that.courseName))
            return false;
        if (!chapterName.equals(that.chapterName))
            return false;
        if (!partName.equals(that.partName))
            return false;
        return url.equals(that.url);
        
    }
    
    @Override
    public int hashCode()
    {
        int result = id;
        result = 31 * result + courseId;
        result = 31 * result + courseName.hashCode();
        result = 31 * result + chapterName.hashCode();
        result = 31 * result + partName.hashCode();
        result = 31 * result + url.hashCode();
        result = 31 * result + status;
        return result;
    }
    
    @Override
    public String toString()
    {
        return "CourseEntity{" + "id=" + id + ", courseId=" + courseId + ", courseName='" + courseName + ", chapterName='" + chapterName + ", partName='" + partName + ", url='"
            + url + ", status=" + status + '}';
    }
}
